<!--  -->
<template>
  <div>
    <c-title text="门店申请详情"></c-title>
    <van-cell-group inset class="t-l margin-top-10">
      <van-cell title="会员" :value="info.nickname" />
      <van-cell title="门店名称" :value="info.store_name" />
      <van-cell title="门店LOGO">
        <template #label>
          <img @click="showImage(info.thumb)" :src="info.thumb" class="t-img"/>
        </template>
      </van-cell>
      <van-cell title="分类" :value="info.category_name" />
      <van-cell title="门店地址" :value="info.address" />
      <van-cell title="详细地址(门牌号)" :value="info.address_detail" />

      <van-cell title="营业时间" :value="info.business_hours" />
      <van-cell title="轮播图">
        <template #label>
          <img @click="showImage(info.banner_thumb)" :src="info.banner_thumb" class="t-img"/>
          <!-- <img v-for="(item, index) in info.banner_thumb" :key="index" @click="showImage(item)" :src="item" class="t-img"/> -->
        </template>
      </van-cell>
      <van-cell title="资质">
        <template #label>
          <div class="flex">
            <img @click="showImage(info.aptitude_imgs[i], info.aptitude_imgs.length, info.aptitude_imgs)" class="t-img" :src="item" v-for="(item, i) in info.aptitude_imgs" :key="item"/>
          </div>
        </template>
      </van-cell>
      <van-cell title="身份证正反面">
        <template #label>
          <div class="flex">
            <img @click="showImage(info.id_card_imgs[i], info.id_card_imgs.length, info.id_card_imgs)" class="t-img" :src="item" v-for="(item, i) in info.id_card_imgs" :key="item"/>
          </div>
        </template>
      </van-cell>
      <van-cell title="其它图片">
        <template #label>
          <div  class="flex">
            <img @click="showImage(info.other_imgs[i], info.other_imgs.length, info.other_imgs)" class="t-img" :src="item" v-for="(item, i) in info.other_imgs" :key="item"/>
          </div>
        </template>
      </van-cell>

      <van-cell title="姓名" :value="info.realname" />
      <van-cell title="店铺电话" :value="info.mobile" />
      <van-cell title="门店简介" :value="info.store_introduce" />
      <van-cell title="备注" :value="info.remark" />
    </van-cell-group>
    <div style="height: 120px;"></div>
  </div>
</template>

<script>
export default {
  data() {
    return {
      info: {}
    };
  },

  activated() {
    this.getData();
  },

  components: {},

  computed: {},

  mounted() {},

  methods: {
    async getData() {
      let { msg, result, data } = await $http.get('plugin.business-district.frontend.controllers.promoter.apply-detail', {apply_id: this.$route.params.apply_id}, ".");
      if (result == 0) {
        return this.$toast(msg);
      }
      this.info = data;
    }
  }
};
</script>
<style lang="scss" rel="stylesheet/scss" scoped>
.t-img{
  width: 5rem;
  border-radius: 0.5rem;
  margin: 0 0.875rem 0 0;
}
</style>
